package com.tomdxz.serviceimpl;

import com.tomdxz.dao.TreeDao;
import com.tomdxz.daoimpl.TreeDaoImpl;
import com.tomdxz.service.TreeService;

import net.sf.json.JSONArray;

public class TreeServiceImpl implements TreeService{

	TreeDao tDao = new TreeDaoImpl();
	
	@Override
	public JSONArray findTreeByPid(int pId,String fId) {
				
		return tDao.getAllTreeByPid(pId, fId);
	}

	@Override
	public String findFidByUid(int uId) {
		
		return tDao.getFidByUid(uId);
	}

	@Override
	public JSONArray findWholeTreeByPid(int pId,String fId) {
		
		return tDao.getWholeAllTreeByPid(pId,fId);
	}

	@Override
	public String findFidByRid(int rId) {
		
		return tDao.getFidByRid(rId);
	}

	@Override
	public JSONArray findOwnTreeByPid(int pId) {
		
		return tDao.getAllOwnTreeByPid(pId);
	}

	

}
